package root.loan;

import exceptions.HasAlreadyDoneException;
import exceptions.LoanHasAlreadyBeenApprovedException;
import exceptions.PermissionDeniedException;

/**
 * 
 * Estado de item que teve emprestimo foi consedido, mas que o item ja foi devolvido ao dono.
 *
 */
public class AcceptedReturned extends Accepted{
	
	@Override
	public void returnItem(Borrow borrow) throws HasAlreadyDoneException {
		throw new HasAlreadyDoneException("Item já devolvido");
	}
	
	@Override
	public void requestDevolution(Borrow borrow) throws HasAlreadyDoneException {
		throw new HasAlreadyDoneException("Item já devolvido");
	}
	
	@Override
	public void cancel(Borrow borrow) throws HasAlreadyDoneException {
		throw new HasAlreadyDoneException("Item já devolvido");
	}
	@Override
	public void complete(Borrow borrow) throws HasAlreadyDoneException {
		mudaEstado(borrow,new Completed());
	}
	
}
